package com.example.mydesignmodule.observer;


/**
 * @author tgw
 * @date 2021/1/22
 */
public class FirstObserver<M,T extends Subject<M>> extends Observer<T> {

    public FirstObserver(T subject){
        this.mySubject = subject;
//        this.mySubject.addObserver(this,this.getClass().getSimpleName());
    }

    @Override
    void update() {
        System.out.println("FirstObserver观察者观察到了observber的变化"+mySubject.getObservber());
    }
}
